<?php
	include "../public/commom/config.php";
	include "/lock1.php";
	
	if($_POST) {
		$id = $_POST["id"];
		$password = MD5($_POST["password"]);
		
		$sql = "UPDATE user SET password = '$password' WHERE id = $id";
			
		$result = mysqli_query($conn, $sql);
		
		session_destroy();
		
		mysqli_close($conn);
			
		echo "<script>top.location='login.php'</script>";
	}
?>